package com.twu.biblioteca.Command;

import com.twu.biblioteca.BibiliotecaModel;

import java.io.PrintWriter;

public class ShowAllMoviesCommand implements IBibiliotecaCommand {
    private PrintWriter out;

    public void ICommand(PrintWriter outputBuffer) {
        out = outputBuffer;
        showAllMovies();
    }

    private void showAllMovies() {
        out.println("view all movies");
        for (int i = 0; i < BibiliotecaModel.getMovies().size(); i++) {
            out.println(BibiliotecaModel.getMovies().get(i).getMovieInfo());
        }
    }
}
